package com.heima.apis.article;

//import com.heima.apis.article.fallback.IArticleClientFallback;
import com.heima.model.article.dtos.ApArticleDto;
import com.heima.model.common.dtos.ResponseResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;



@FeignClient(value = "leadnews-article"/*,fallback = IArticleClientFallback.class*/)
public interface IArticleClient {

    @PostMapping("/api/v1/article/save")
    public ResponseResult saveArticle(@RequestBody ApArticleDto dto) ;

    @PostMapping("/api/v1/article/down")
    String down(@RequestBody Long articleId);

    @DeleteMapping("/api/v1/article/delete")
    ResponseResult delete(@RequestBody Long articleId);
}